﻿// Admin.NET 项目的版权、商标、专利和其他相关权利均受相应法律法规的保护。使用本项目应遵守相关法律法规和许可证的要求。
//
// 本项目主要遵循 MIT 许可证和 Apache 许可证（版本 2.0）进行分发和使用。许可证位于源代码树根目录中的 LICENSE-MIT 和 LICENSE-APACHE 文件。
//
// 不得利用本项目从事危害国家安全、扰乱社会秩序、侵犯他人合法权益等法律法规禁止的活动！任何基于本项目二次开发而产生的一切法律纠纷和责任，我们不承担任何责任！

using Admin.NET.Core;
using Magicodes.ExporterAndImporter.Core;
using Magicodes.ExporterAndImporter.Excel;
using System.ComponentModel.DataAnnotations;

namespace Admin.NET.Application;

/// <summary>
/// 货品信息表基础输入参数
/// </summary>
public class GoodsinfoBaseInput
{
    /// <summary>
    /// 主键Id
    /// </summary>
    public virtual long? Id { get; set; }
    
    /// <summary>
    /// 货品名称
    /// </summary>
    public virtual string? GoodsName { get; set; }
    
    /// <summary>
    /// 货品编号
    /// </summary>
    public virtual string? GoodsNumber { get; set; }
    
    /// <summary>
    /// 货品类型
    /// </summary>
    public virtual long? GoodsTypeId { get; set; }
    
    /// <summary>
    /// 规格型号
    /// </summary>
    public virtual string? SpecificationsModels { get; set; }
    
    /// <summary>
    /// 供应商
    /// </summary>
    public virtual long? vendorId { get; set; }
    
    /// <summary>
    /// 客户名称
    /// </summary>
    public virtual long? CustomersId { get; set; }
    
    /// <summary>
    /// 入库参考价
    /// </summary>
    public virtual decimal? StoragePrice { get; set; }
    
    /// <summary>
    /// 出库参考价
    /// </summary>
    public virtual decimal? OutboundPrice { get; set; }
    
    /// <summary>
    /// 顺序
    /// </summary>
    public virtual int? Sort { get; set; }
    
    /// <summary>
    /// 状态
    /// </summary>
    public virtual bool? Status { get; set; }
    
    /// <summary>
    /// 保质期管理
    /// </summary>
    public virtual string? ShelfLife { get; set; }
    
    /// <summary>
    /// 预警天数
    /// </summary>
    public virtual int? EarlyWarningDays { get; set; }
    
    /// <summary>
    /// 备注
    /// </summary>
    public virtual string? Desc { get; set; }
    
    /// <summary>
    /// 条码
    /// </summary>
    public virtual string? Barcodes { get; set; }
    
    /// <summary>
    /// 当前库存
    /// </summary>
    public virtual int? CurrentInventory { get; set; }
    
    /// <summary>
    /// 库存总金额
    /// </summary>
    public virtual decimal? inventoryMoney { get; set; }
    
    /// <summary>
    /// 单位
    /// </summary>
    public virtual long? Unitid { get; set; }
    
}

/// <summary>
/// 货品信息表分页查询输入参数
/// </summary>
public class PageGoodsinfoInput : BasePageInput
{
    /// <summary>
    /// 货品名称
    /// </summary>
    public string? GoodsName { get; set; }
    
    /// <summary>
    /// 货品编号
    /// </summary>
    public string? GoodsNumber { get; set; }
    
    /// <summary>
    /// 货品类型
    /// </summary>
    public long? GoodsTypeId { get; set; }
    
    /// <summary>
    /// 规格型号
    /// </summary>
    public string? SpecificationsModels { get; set; }
    
    /// <summary>
    /// 供应商
    /// </summary>
    public long? vendorId { get; set; }
    
    /// <summary>
    /// 客户名称
    /// </summary>
    public long? CustomersId { get; set; }
    
    /// <summary>
    /// 入库参考价
    /// </summary>
    public decimal? StoragePrice { get; set; }
    
    /// <summary>
    /// 出库参考价
    /// </summary>
    public decimal? OutboundPrice { get; set; }
    
    /// <summary>
    /// 顺序
    /// </summary>
    public int? Sort { get; set; }
    
    /// <summary>
    /// 状态
    /// </summary>
    public bool? Status { get; set; }
    
    /// <summary>
    /// 保质期管理
    /// </summary>
    public string? ShelfLife { get; set; }
    
    /// <summary>
    /// 预警天数
    /// </summary>
    public int? EarlyWarningDays { get; set; }
    
    /// <summary>
    /// 备注
    /// </summary>
    public string? Desc { get; set; }
    
    /// <summary>
    /// 条码
    /// </summary>
    public string? Barcodes { get; set; }
    
    /// <summary>
    /// 当前库存
    /// </summary>
    public int? CurrentInventory { get; set; }
    
    /// <summary>
    /// 库存总金额
    /// </summary>
    public decimal? inventoryMoney { get; set; }
    
    /// <summary>
    /// 单位
    /// </summary>
    public long? Unitid { get; set; }
    
    /// <summary>
    /// 选中主键列表
    /// </summary>
     public List<long> SelectKeyList { get; set; }
}

/// <summary>
/// 货品信息表增加输入参数
/// </summary>
public class AddGoodsinfoInput
{
    /// <summary>
    /// 货品名称
    /// </summary>
    [MaxLength(32, ErrorMessage = "货品名称字符长度不能超过32")]
    public string? GoodsName { get; set; }
    
    /// <summary>
    /// 货品编号
    /// </summary>
    [MaxLength(32, ErrorMessage = "货品编号字符长度不能超过32")]
    public string? GoodsNumber { get; set; }
    
    /// <summary>
    /// 货品类型
    /// </summary>
    public long? GoodsTypeId { get; set; }
    
    /// <summary>
    /// 规格型号
    /// </summary>
    [MaxLength(32, ErrorMessage = "规格型号字符长度不能超过32")]
    public string? SpecificationsModels { get; set; }
    
    /// <summary>
    /// 供应商
    /// </summary>
    public long? vendorId { get; set; }
    
    /// <summary>
    /// 客户名称
    /// </summary>
    public long? CustomersId { get; set; }
    
    /// <summary>
    /// 入库参考价
    /// </summary>
    public decimal? StoragePrice { get; set; }
    
    /// <summary>
    /// 出库参考价
    /// </summary>
    public decimal? OutboundPrice { get; set; }
    
    /// <summary>
    /// 顺序
    /// </summary>
    public int? Sort { get; set; }
    
    /// <summary>
    /// 状态
    /// </summary>
    public bool? Status { get; set; }
    
    /// <summary>
    /// 保质期管理
    /// </summary>
    [MaxLength(32, ErrorMessage = "保质期管理字符长度不能超过32")]
    public string? ShelfLife { get; set; }
    
    /// <summary>
    /// 预警天数
    /// </summary>
    public int? EarlyWarningDays { get; set; }
    
    /// <summary>
    /// 备注
    /// </summary>
    [MaxLength(300, ErrorMessage = "备注字符长度不能超过300")]
    public string? Desc { get; set; }
    
    /// <summary>
    /// 条码
    /// </summary>
    [MaxLength(32, ErrorMessage = "条码字符长度不能超过32")]
    public string? Barcodes { get; set; }
    
    /// <summary>
    /// 当前库存
    /// </summary>
    public int? CurrentInventory { get; set; }
    
    /// <summary>
    /// 库存总金额
    /// </summary>
    public decimal? inventoryMoney { get; set; }
    
    /// <summary>
    /// 单位
    /// </summary>
    public long? Unitid { get; set; }
    
}

/// <summary>
/// 货品信息表删除输入参数
/// </summary>
public class DeleteGoodsinfoInput
{
    /// <summary>
    /// 主键Id
    /// </summary>
    [Required(ErrorMessage = "主键Id不能为空")]
    public long? Id { get; set; }
    
}

/// <summary>
/// 货品信息表更新输入参数
/// </summary>
public class UpdateGoodsinfoInput
{
    /// <summary>
    /// 主键Id
    /// </summary>    
    [Required(ErrorMessage = "主键Id不能为空")]
    public long? Id { get; set; }
    
    /// <summary>
    /// 货品名称
    /// </summary>    
    [MaxLength(32, ErrorMessage = "货品名称字符长度不能超过32")]
    public string? GoodsName { get; set; }
    
    /// <summary>
    /// 货品编号
    /// </summary>    
    [MaxLength(32, ErrorMessage = "货品编号字符长度不能超过32")]
    public string? GoodsNumber { get; set; }
    
    /// <summary>
    /// 货品类型
    /// </summary>    
    public long? GoodsTypeId { get; set; }
    
    /// <summary>
    /// 规格型号
    /// </summary>    
    [MaxLength(32, ErrorMessage = "规格型号字符长度不能超过32")]
    public string? SpecificationsModels { get; set; }
    
    /// <summary>
    /// 供应商
    /// </summary>    
    public long? vendorId { get; set; }
    
    /// <summary>
    /// 客户名称
    /// </summary>    
    public long? CustomersId { get; set; }
    
    /// <summary>
    /// 入库参考价
    /// </summary>    
    public decimal? StoragePrice { get; set; }
    
    /// <summary>
    /// 出库参考价
    /// </summary>    
    public decimal? OutboundPrice { get; set; }
    
    /// <summary>
    /// 顺序
    /// </summary>    
    public int? Sort { get; set; }
    
    /// <summary>
    /// 状态
    /// </summary>    
    public bool? Status { get; set; }
    
    /// <summary>
    /// 保质期管理
    /// </summary>    
    [MaxLength(32, ErrorMessage = "保质期管理字符长度不能超过32")]
    public string? ShelfLife { get; set; }
    
    /// <summary>
    /// 预警天数
    /// </summary>    
    public int? EarlyWarningDays { get; set; }
    
    /// <summary>
    /// 备注
    /// </summary>    
    [MaxLength(300, ErrorMessage = "备注字符长度不能超过300")]
    public string? Desc { get; set; }
    
    /// <summary>
    /// 条码
    /// </summary>    
    [MaxLength(32, ErrorMessage = "条码字符长度不能超过32")]
    public string? Barcodes { get; set; }
    
    /// <summary>
    /// 当前库存
    /// </summary>    
    public int? CurrentInventory { get; set; }
    
    /// <summary>
    /// 库存总金额
    /// </summary>    
    public decimal? inventoryMoney { get; set; }
    
    /// <summary>
    /// 单位
    /// </summary>    
    public long? Unitid { get; set; }
    
}

/// <summary>
/// 货品信息表主键查询输入参数
/// </summary>
public class QueryByIdGoodsinfoInput : DeleteGoodsinfoInput
{
}

/// <summary>
/// 下拉数据输入参数
/// </summary>
public class DropdownDataGoodsinfoInput
{
    /// <summary>
    /// 是否用于分页查询
    /// </summary>
    public bool FromPage { get; set; }
}

/// <summary>
/// 货品信息表数据导入实体
/// </summary>
[ExcelImporter(SheetIndex = 1, IsOnlyErrorRows = true)]
public class ImportGoodsinfoInput : BaseImportInput
{
    /// <summary>
    /// 货品名称
    /// </summary>
    [ImporterHeader(Name = "货品名称")]
    [ExporterHeader("货品名称", Format = "", Width = 25, IsBold = true)]
    public string? GoodsName { get; set; }
    
    /// <summary>
    /// 货品编号
    /// </summary>
    [ImporterHeader(Name = "货品编号")]
    [ExporterHeader("货品编号", Format = "", Width = 25, IsBold = true)]
    public string? GoodsNumber { get; set; }
    
    /// <summary>
    /// 货品类型 关联值
    /// </summary>
    [ImporterHeader(IsIgnore = true)]
    [ExporterHeader(IsIgnore = true)]
    public long? GoodsTypeId { get; set; }
    
    /// <summary>
    /// 货品类型 文本
    /// </summary>
    [ImporterHeader(Name = "货品类型")]
    [ExporterHeader("货品类型", Format = "", Width = 25, IsBold = true)]
    public string GoodsTypeDisplayName { get; set; }
    
    /// <summary>
    /// 规格型号
    /// </summary>
    [ImporterHeader(Name = "规格型号")]
    [ExporterHeader("规格型号", Format = "", Width = 25, IsBold = true)]
    public string? SpecificationsModels { get; set; }
    
    /// <summary>
    /// 供应商 关联值
    /// </summary>
    [ImporterHeader(IsIgnore = true)]
    [ExporterHeader(IsIgnore = true)]
    public long? vendorId { get; set; }
    
    /// <summary>
    /// 供应商 文本
    /// </summary>
    [ImporterHeader(Name = "供应商")]
    [ExporterHeader("供应商", Format = "", Width = 25, IsBold = true)]
    public string vendorFkDisplayName { get; set; }
    
    /// <summary>
    /// 客户名称 关联值
    /// </summary>
    [ImporterHeader(IsIgnore = true)]
    [ExporterHeader(IsIgnore = true)]
    public long? CustomersId { get; set; }
    
    /// <summary>
    /// 客户名称 文本
    /// </summary>
    [ImporterHeader(Name = "客户名称")]
    [ExporterHeader("客户名称", Format = "", Width = 25, IsBold = true)]
    public string CustomersFkDisplayName { get; set; }
    
    /// <summary>
    /// 入库参考价
    /// </summary>
    [ImporterHeader(Name = "入库参考价")]
    [ExporterHeader("入库参考价", Format = "", Width = 25, IsBold = true)]
    public decimal? StoragePrice { get; set; }
    
    /// <summary>
    /// 出库参考价
    /// </summary>
    [ImporterHeader(Name = "出库参考价")]
    [ExporterHeader("出库参考价", Format = "", Width = 25, IsBold = true)]
    public decimal? OutboundPrice { get; set; }
    
    /// <summary>
    /// 顺序
    /// </summary>
    [ImporterHeader(Name = "顺序")]
    [ExporterHeader("顺序", Format = "", Width = 25, IsBold = true)]
    public int? Sort { get; set; }
    
    /// <summary>
    /// 状态
    /// </summary>
    [ImporterHeader(Name = "状态")]
    [ExporterHeader("状态", Format = "", Width = 25, IsBold = true)]
    public bool? Status { get; set; }
    
    /// <summary>
    /// 保质期管理
    /// </summary>
    [ImporterHeader(Name = "保质期管理")]
    [ExporterHeader("保质期管理", Format = "", Width = 25, IsBold = true)]
    public string? ShelfLife { get; set; }
    
    /// <summary>
    /// 预警天数
    /// </summary>
    [ImporterHeader(Name = "预警天数")]
    [ExporterHeader("预警天数", Format = "", Width = 25, IsBold = true)]
    public int? EarlyWarningDays { get; set; }
    
    /// <summary>
    /// 备注
    /// </summary>
    [ImporterHeader(Name = "备注")]
    [ExporterHeader("备注", Format = "", Width = 25, IsBold = true)]
    public string? Desc { get; set; }
    
    /// <summary>
    /// 条码
    /// </summary>
    [ImporterHeader(Name = "条码")]
    [ExporterHeader("条码", Format = "", Width = 25, IsBold = true)]
    public string? Barcodes { get; set; }
    
    /// <summary>
    /// 当前库存
    /// </summary>
    [ImporterHeader(Name = "当前库存")]
    [ExporterHeader("当前库存", Format = "", Width = 25, IsBold = true)]
    public int? CurrentInventory { get; set; }
    
    /// <summary>
    /// 库存总金额
    /// </summary>
    [ImporterHeader(Name = "库存总金额")]
    [ExporterHeader("库存总金额", Format = "", Width = 25, IsBold = true)]
    public decimal? inventoryMoney { get; set; }
    
    /// <summary>
    /// 单位 关联值
    /// </summary>
    [ImporterHeader(IsIgnore = true)]
    [ExporterHeader(IsIgnore = true)]
    public long? Unitid { get; set; }
    
    /// <summary>
    /// 单位 文本
    /// </summary>
    [ImporterHeader(Name = "单位")]
    [ExporterHeader("单位", Format = "", Width = 25, IsBold = true)]
    public string UnitFkDisplayName { get; set; }
    
}
